package com.fasteat.menu.service.impl;

import com.fasteat.menu.entity.Material;
import com.fasteat.menu.mapper.MaterialMapper;
import com.fasteat.menu.service.MaterialService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author run
 * @since 2021-01-19
 */
@Service
public class MaterialServiceImpl extends ServiceImpl<MaterialMapper, Material> implements MaterialService {

    @Autowired
    private MaterialMapper materialMapper;

    @Override
    public List<Material> searchMaterialsOfMenu(String menuId) {
        return materialMapper.findMaterialsOfMenu(menuId);
    }
}
